/*所有的渲染转发都放这*/
import { Router } from "./components/router/index";
import Header from "./components/header";
import Demo1 from "./page/demo1.js";
import Demo2 from "./page/demo2.js";
import Demo3 from "./page/demo3.js";
import Footer from "./components/footer";

import {getNavbar} from "./data/data.js";

let NavbarMent = [];




class App extends Element {
	this(props){
		this.url = props.url
	}
    render() {
        return ( 
          <div id="container">
                <Header ment={NavbarMent}    />
                <div id="conent">
                <Router url={"/demo1/index1/999"}  >
                    <Demo1   path="/demo1/:*"   data={NavbarMent}  />
                    <Demo2   path="/demo2/:*"    />
                    <Demo3   path="/demo3/:*"    />
                </Router >
                </div>
                <Footer />
          </div>
        );
    }
}







getNavbar().then(res=>{
    console.log('res',res)
    NavbarMent = res;
    document.$("div#root").patch(<App />)
  });
 

